import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import * as api from './api'  // 假设你的API文件路径是 ./api.js

const app = createApp(App)

// 配置Element Plus
app.use(ElementPlus)

// 挂载全局API（替代Vue.prototype）
app.config.globalProperties.$api = api

// 挂载应用
app.use(router)
app.mount('#app')